/*
 * @Author: ChenYu ycyplus@gmail.com
 * @Date: 2025-12-02 10:58:00
 * @LastEditors: ChenYu ycyplus@gmail.com
 * @LastEditTime: 2025-12-02 10:58:00
 * @FilePath: \Robot_Admin\src\views\demo\36-map\index.scss
 * @Description: 地图演示页面样式
 * Copyright (c) 2025 by CHENY, All Rights Reserved 😎.
 */

.map-demo {
  padding: 20px;

  .demo-section {
    margin-bottom: 32px;

    .section-title {
      font-size: 18px;
      font-weight: 600;
      margin-bottom: 16px;
      color: #333;
      display: flex;
      align-items: center;
      gap: 8px;

      .title-icon {
        color: var(--primary-color, #409eff);
      }
    }

    .section-desc {
      color: #666;
      margin-bottom: 20px;
      line-height: 1.6;
    }
  }

  .examples-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 32px;

    .example-card {
      background: #fff;
      border: 1px solid #e8e8e8;
      border-radius: 8px;
      padding: 20px;
      transition: all 0.3s ease;

      &:hover {
        border-color: var(--primary-color, #409eff);
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
        transform: translateY(-2px);
      }

      .example-title {
        font-size: 16px;
        font-weight: 600;
        margin-bottom: 8px;
        color: #333;
      }

      .example-desc {
        color: #666;
        font-size: 14px;
        margin-bottom: 16px;
        line-height: 1.5;
      }

      .example-map {
        height: 250px;
        border-radius: 4px;
        overflow: hidden;
        border: 1px solid #e0e0e0;
      }
    }
  }

  .control-panel {
    background: #fff;
    border: 1px solid #e8e8e8;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 32px;

    .control-row {
      display: flex;
      align-items: center;
      margin-bottom: 16px;
      gap: 16px;
      flex-wrap: wrap;

      .control-label {
        min-width: 80px;
        font-weight: 500;
        color: #333;
      }

      .control-content {
        flex: 1;
        display: flex;
        align-items: center;
        gap: 12px;
      }

      .amap-note {
        flex: 1 1;
        padding: 12px;
        background: #fff3cd;
        border: 1px solid #ffe7b3;
        border-radius: 4px;
        font-size: 13px;
        color: #856404;
        margin-top: 8px;
      }
    }
  }

  .preview-section {
    background: #fff;
    border: 1px solid #e8e8e8;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 32px;

    .preview-title {
      font-size: 16px;
      font-weight: 600;
      margin-bottom: 20px;
      color: #333;
      text-align: center;
    }

    .preview-map {
      height: 400px;
      border-radius: 8px;
      overflow: hidden;
      border: 1px solid #e0e0e0;
      margin-bottom: 16px;
    }

    .preview-info {
      display: flex;
      justify-content: center;
      gap: 24px;
      font-size: 14px;
      color: #666;
      flex-wrap: wrap;

      .info-item {
        display: flex;
        align-items: center;
        gap: 4px;
        margin-bottom: 8px;

        .info-label {
          font-weight: 500;
        }

        .info-value {
          color: var(--primary-color, #409eff);
          font-family: 'Courier New', monospace;
        }
      }
    }
  }

  .action-buttons {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-top: 24px;
    flex-wrap: wrap;

    .action-button {
      min-width: 120px;
    }
  }
}

// 响应式设计
@media (max-width: 768px) {
  .map-demo {
    padding: 16px;

    .examples-grid {
      grid-template-columns: 1fr;
      gap: 12px;

      .example-card {
        padding: 12px;

        .example-title {
          font-size: 15px;
        }

        .example-desc {
          font-size: 13px;
          margin-bottom: 12px;
        }

        .example-map {
          height: 200px;
        }
      }
    }

    .control-panel {
      padding: 16px;

      .control-row {
        gap: 12px;
        margin-bottom: 12px;

        .control-content {
          gap: 8px;
        }
      }
    }

    .preview-section {
      padding: 16px;

      .preview-title {
        font-size: 15px;
        margin-bottom: 16px;
      }

      .preview-map {
        height: 300px;
      }

      .preview-info {
        gap: 16px;
        font-size: 13px;

        .info-item {
          margin-bottom: 6px;
        }
      }
    }

    .action-buttons {
      gap: 8px;
      margin-top: 16px;

      .action-button {
        min-width: 100px;
      }
    }
  }
}

@media (max-width: 480px) {
  .map-demo {
    padding: 12px;

    .examples-grid {
      .example-card {
        padding: 10px;

        .example-map {
          height: 180px;
        }
      }
    }

    .control-panel {
      padding: 12px;

      .control-row {
        .control-content {
          gap: 6px;
        }
      }
    }

    .preview-section {
      padding: 12px;

      .preview-map {
        height: 250px;
      }
    }

    .action-buttons {
      .action-button {
        min-width: 80px;
        padding: 8px 12px;
      }
    }
  }
}
